package util.AST.Statement;

import java.util.ArrayList;

import checker.SemanticException;
import checker.Visitor;

import util.AST.Expression.Expression;

public class IfElseStatement extends Statement{

	private Expression condition;
    private ArrayList<Statement> ifStmts;
    private ArrayList<Statement> elseStmts;
	
    public IfElseStatement(Expression condition, ArrayList<Statement> ifStatements, ArrayList<Statement> elseStatements) {
        this.condition = condition;
        this.ifStmts = ifStatements;
        this.elseStmts= elseStatements;
	}
	
	public Expression getCondition() {
	        return condition;
	}
	
	public ArrayList<Statement> getIfStatements() {
	        return ifStmts;
	}
	
	public ArrayList<Statement> getElseStatements() {
	        return elseStmts;
	}
    
	@Override
	public String toString(int level) {
		// TODO Auto-generated method stub
		return null;
	}

	@Override
	public Object visit(Visitor v, Object o) throws SemanticException {
		// TODO Auto-generated method stub
		return v.visitIfElseStatement(this, o);
	}
	
}
